package com.freak.kotlinfitnessserver.factory.notify

import com.freak.kotlinfitnessserver.data.FitnessConfigData
import com.freak.kotlinfitnessserver.data.SportStatusData
import com.freak.kotlinfitnessserver.factory.INotifyFactory

class TrainingStatusNotifyFactory : INotifyFactory {
    override fun getNotifyByteArray(
        sportStatus: Int,
        fitnessConfigData: FitnessConfigData?
    ): ByteArray {
        when (sportStatus) {
            SportStatusData.SPORT_IDLE -> {
                return byteArrayOf(1, 1)
            }

            SportStatusData.SPORT_STOP -> {
                return byteArrayOf(1, 1)
            }

            SportStatusData.SPORT_PAUSE -> {
                return byteArrayOf(1, 1)
            }

            SportStatusData.SPORT_SPORTING -> {
                return byteArrayOf(1, 0x0d)
            }
        }
        return ByteArray(0)
    }

    override fun getNotifyByteArrayList(
        sportStatus: Int,
        fitnessConfigData: FitnessConfigData?
    ): List<ByteArray> {
        return ArrayList<ByteArray>()
    }
}